# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=krdc
pkgver=20.04.3
pkgrel=0
arch="all !armhf"
url="https://kde.org/applications/internet/krdc/"
pkgdesc="Remote Desktop Client"
license="GPL-2.0-or-later AND GFDL-1.2-only"
depends="freerdp"
makedepends="extra-cmake-modules kconfig-dev kcmutils-dev kdnssd-dev knotifyconfig-dev knotifications-dev kbookmarks-dev kiconthemes-dev kxmlgui-dev kcompletion-dev kwallet-dev kwidgetsaddons-dev kwindowsystem-dev knotifyconfig-dev ki18n-dev kdoctools-dev libvncserver-dev libssh-dev"
source="https://download.kde.org/stable/release-service/$pkgver/src/krdc-$pkgver.tar.xz"
subpackages="$pkgname-doc $pkgname-lang"

build() {
	cmake -B build \
		-DCMAKE_BUILD_TYPE=None \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib
	cmake --build build
}

check() {
	cd build
	CTEST_OUTPUT_ON_FAILURE=TRUE ctest
}

package() {
	DESTDIR="$pkgdir" cmake --build build --target install
}

sha512sums="f7ff9be6ffa612e8da0766309f812e7041393eb9b5ff4b1cb58385f1f754c0851357a4509bff7eea76e0e035bcefac9580415710561f1369dab1dd4e9f86a4ff  krdc-20.04.3.tar.xz"
